Add a secure GtkEntryBuffer
authorEmmanuele Bassi <ebassi@gnome.org>
Fri, 4 Sep 2020 11:51:58 +0000 (12:51 +0100)
committerEmmanuele Bassi <ebassi@gnome.org>
Tue, 8 Sep 2020 22:50:12 +0000 (23:50 +0100)
commitfb99bde840a30fe4ba431c8cde9b3c8eded7b7f8
tree29a639b18b8952d9f1df237331a5b0401da26e24
parent9dc5c6a0f3c34fc6192583e3cfa24e2f4ec4054c
Add a secure GtkEntryBuffer

We have a widget for password and passphrase entries, but we have no way
to handle the data securely. This is usually performed by a separate
GtkEntryBuffer—for instance, the one in GCR. While we have API for
setting a new entry buffer on GtkText, we don't have API for
GtkPasswordEntry, though, so the options are:

 - expose additional API for GtkPasswordEntry to allow setting a secure
   text buffer on the internal GtkText widget
 - provide a secure text buffer out of the box

Given that an insecure-by-default GtkPasswordEntry is basically
pointless, might as well have a secure buffer built in.

We don't really need to make the password entry buffer public out of the
box, but we can re-evaluate at a later date.

Fixes: #2403
gtk/gtkpasswordentrybuffer.c [new file with mode: 0644]
gtk/gtkpasswordentrybufferprivate.h [new file with mode: 0644]
gtk/meson.build